package com.example.demo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 来访者，普通需要咨询的人
 * </p>
 *
 * @author hyb
 * @since 2024-12-24
 */
@Data//自动生成getter，setter等
@EqualsAndHashCode(callSuper = false)
public class User implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 来访者账号
     */
    @TableId(value = "client_id", type = IdType.AUTO)
    private Integer clientId;

    /**
     * 来访者登录的密码
     */
    private String password;

    /**
     * 来访者姓名
     */
    private String name;

    /**
     * 0女，1男
     */
    private Integer sex;

    /**
     * 来访者电子邮件
     */
    private String email;

    /**
     * 来访者账户状态  0停用，1激活
     */
    private Integer isActive;

    /**
     * 记录最后更新时间
     */
    private LocalDateTime updateTime;

    /**
     * 用户创建时间
     */
    private LocalDateTime createTime;
    public User(Integer clientId,String password,String name,Integer sex,String email){
        this.clientId=clientId;
        this.password=password;
        this.name=name;
        this.sex=sex;
        this.email=email;
        this.isActive=1;
        this.updateTime=LocalDateTime.now();
        this.createTime=LocalDateTime.now();
    }


}
